package com.wxisme.ssm.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;

import com.wxisme.ssm.mapper.AlbumMapper;
import com.wxisme.ssm.po.Album;
import com.wxisme.ssm.service.AlbumService;

/**
 *AlbumServiceImpl
 *@author wxisme
 *@time 2015-9-15 上午10:39:15
 */
public class AlbumServiceImpl implements AlbumService {
	
	@Autowired
	private AlbumMapper albumMapper;
	
	@Override
	public void insertAlbum(Album album) throws Exception {
		albumMapper.insertAlbum(album);
	}
	
	@Override
	public List<Album> selectAlbumByUsername(String username) throws Exception {
		
		return albumMapper.selectAlbumByUsername(username);
	}
	
	
	@Override
	public void updatePhotoNumber(Album album) throws Exception {
		albumMapper.updatePhotoNumber(album);
	}
	
	@Override
	public void deleteAlbum(String pathName) throws Exception {
		albumMapper.deleteAlbum(pathName);
	}
	
	@Override
	public List<Album> selectAlbumByFriendname(String friendname)
			throws Exception {
		return albumMapper.selectAlbumByFriendname(friendname);
	}

}
